package org.oexam.ostudy.sl;

import java.sql.SQLException;

import javax.naming.NamingException;

import org.oexam.ostudy.db.GeneralAnnoucementsAccess;
import org.oexam.ostudy.struct.General_announcementsList;

public class General_Announcements {
	
	public General_announcementsList getHeadlines() throws SQLException, NamingException{
		
		GeneralAnnoucementsAccess general_annoucements = new GeneralAnnoucementsAccess();
		
		General_announcementsList dtls = new General_announcementsList();
		
		
		dtls = general_annoucements.getAllHeadlines();
		
		return dtls;
	}
	
	public String insertAnnouncements(String news) throws SQLException, NamingException{
		
		return new GeneralAnnoucementsAccess().insertAnnouncement(news);
	}

}
